<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
		<script type="text/javascript" src="auction.js" ></script>
		<title>Auction 4 u</title>
		<link rel="stylesheet" type="text/css" href="style/style1.css" />
		<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
		<%
		response.setHeader("Cache-Control","no-cache"); //http 1.0
		response.setHeader("Cache-Control", "no-cache, no-store, must-revalidate");//http 1.1
		response.setHeader("Pragma","no-cache"); 
		response.setHeader("Expires", "01 Apr 1995 01:10:10 GMT"); 
		boolean registered = true;
		String user = (String)session.getAttribute("username");
		if(user == null){
			user = "";
			registered = false;
		}
		%>
	</head>
	<body>
		<div id="wrapper">
			<div id="header">
				<a href="#" onclick="changeContent('auctions.jsp')"><img src="img/banner.png" border="0" /></a> 
			</div>
			<div id="navbar">
				<table class="main" style="width: 100%;">
					<tr>
						<%
						String beheerString = "";
						String logString = "";
						String welcome = "";
						if(!registered){
							logString = "<a href=\"#\" onclick=\"setVisible('login');return false\" target=\"_self\">Login</a> | <a href=\"#\" onclick=\"setVisible('register');return false\" target=\"_self\">Register</a>";
							welcome = "Please login";
						}
						else{
							beheerString = " | <a href=\"#\" onclick=\"changeContent('beheer.jsp')\">Manage</a>";
							logString = "<a href=\"servlet\" >Logout</a>";
							welcome = "Welcome back, ";
						}
						%>
						<td class="main" style="text-align: left; padding-left: 20px;"><a href="#" onclick="changeContent('auctions.jsp')">Auctions</a><%=beheerString %></td>
						<td class="main" style="text-align: right; padding-right: 20px;"><%=welcome %><%=user %>. <%=logString %></td>
					</tr>
				</table>
			</div>
			<!-- hieronder een foreach voor alle artikelen van minder dan een week te gaan -->
			<div id="content">
				
			</div>
			<script type="text/javascript">changeContent("auctions.jsp");</script>
			<div id="footer">
			</div>
		</div>
		<div id="login" class="signin-box" style="width: 512px; height: 300px">
			<jsp:include page="WEB-INF/login.html" />
		</div>
		<div id="register" class="signin-box" style="width: 512px; height: 375px">
			<jsp:include page="WEB-INF/register.html" />
		</div>
		<div id="bid" class="signin-box" style="width: 512px; height: 175px">
			<jsp:include page="WEB-INF/placeBid.jsp" />
		</div>
	</body>
</html>